# Time-and-date variable syntax

Tip: | Embedded variables are case sensitive, and must be in the proper format and syntax to work. If you make a mistake, your variable will be treated as a piece of text. Therefore, do not attempt to edit embedded variables manually. Use the Insert Variable and Edit variable dialog boxes to avoid problems. The time-and-date formats in the list will be displayed in the language of the operating system as defined in the Regional Options tab of the Regional and Language Options dialog box in the Control Panel. The time and date will be displayed in the current language of the application.

Time and date embedded variables use this format:

/*Time_date_format*/

The syntax is:

- an opening escape sequence ‘/*’
- followed by one or more 'characters' representing the time and or date format
- followed by a closing escape sequence '*/'

Time_date_format uses one of these character sequences to specify the format:

Select this option from the drop-down list | To insert these characters | This format is called
29/11/2000 | SD | Short date
November 29, 2000 | LD | Long date
29/11/2000 3:39:03 PM | SDT | Short date and time
November 29, 2000 3:39:03 PM | LDT | Long date and time
3:39:03 PM | T | Time
3:39:03 PM 29/11/2000 | TSD | Time and short date
3:39:03 PM November 29, 2000 | TLD | Time and long date

For example, to display the time followed by the short date, you would select this option from the list:

3:39:03 PM 29/11/2000

The time-and-date variable would appear as this:

/*TSD*/

On the display during development, the variable displays the time it was created until the display is closed and reopened. It will then show the time the display was reopened.

At run time, the variable will update continuously.

A space appears between the time and date when the embedded variable is displayed at run time.

## See also

About embedded variables

Insert a time/date variable

Embed a variable in a caption

Embed a variable in a message